<div class="segments view">
<h2><?php  __('Segment');?></h2>
	<dl><?php $i = 0; $class = ' class="altrow"';?>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Id'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['id']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Day'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $this->Html->link($segment['Day']['name'], array('controller' => 'days', 'action' => 'view', $segment['Day']['id'])); ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Horario Desde'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['horario_desde']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Horario Hasta'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['horario_hasta']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Duracion'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['duracion']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Sexo'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['sexo']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Edad Desde'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['edad_desde']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Edad Hasta'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['edad_hasta']; ?>
			&nbsp;
		</dd>
		<dt<?php if ($i % 2 == 0) echo $class;?>><?php __('Sobreturno'); ?></dt>
		<dd<?php if ($i++ % 2 == 0) echo $class;?>>
			<?php echo $segment['Segment']['sobreturno']; ?>
			&nbsp;
		</dd>
	</dl>
</div>
<div class="actions">
	<h3><?php __('Actions'); ?></h3>
	<ul>
		<li><?php echo $this->Html->link(__('Edit Segment', true), array('action' => 'edit', $segment['Segment']['id'])); ?> </li>
		<li><?php echo $this->Html->link(__('Delete Segment', true), array('action' => 'delete', $segment['Segment']['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $segment['Segment']['id'])); ?> </li>
		<li><?php echo $this->Html->link(__('List Segments', true), array('action' => 'index')); ?> </li>
		<li><?php echo $this->Html->link(__('New Segment', true), array('action' => 'add')); ?> </li>
		<li><?php echo $this->Html->link(__('List Days', true), array('controller' => 'days', 'action' => 'index')); ?> </li>
		<li><?php echo $this->Html->link(__('New Day', true), array('controller' => 'days', 'action' => 'add')); ?> </li>
		<li><?php echo $this->Html->link(__('List Agendas', true), array('controller' => 'agendas', 'action' => 'index')); ?> </li>
		<li><?php echo $this->Html->link(__('New Agenda', true), array('controller' => 'agendas', 'action' => 'add')); ?> </li>
	</ul>
</div>
<div class="related">
	<h3><?php __('Related Agendas');?></h3>
	<?php if (!empty($segment['Agenda'])):?>
	<table cellpadding = "0" cellspacing = "0">
	<tr>
		<th><?php __('Id'); ?></th>
		<th><?php __('Client Id'); ?></th>
		<th><?php __('User Id'); ?></th>
		<th><?php __('Created'); ?></th>
		<th><?php __('Modified'); ?></th>
		<th class="actions"><?php __('Actions');?></th>
	</tr>
	<?php
		$i = 0;
		foreach ($segment['Agenda'] as $agenda):
			$class = null;
			if ($i++ % 2 == 0) {
				$class = ' class="altrow"';
			}
		?>
		<tr<?php echo $class;?>>
			<td><?php echo $agenda['id'];?></td>
			<td><?php echo $agenda['client_id'];?></td>
			<td><?php echo $agenda['user_id'];?></td>
			<td><?php echo $agenda['created'];?></td>
			<td><?php echo $agenda['modified'];?></td>
			<td class="actions">
				<?php echo $this->Html->link(__('View', true), array('controller' => 'agendas', 'action' => 'view', $agenda['id'])); ?>
				<?php echo $this->Html->link(__('Edit', true), array('controller' => 'agendas', 'action' => 'edit', $agenda['id'])); ?>
				<?php echo $this->Html->link(__('Delete', true), array('controller' => 'agendas', 'action' => 'delete', $agenda['id']), null, sprintf(__('Are you sure you want to delete # %s?', true), $agenda['id'])); ?>
			</td>
		</tr>
	<?php endforeach; ?>
	</table>
<?php endif; ?>

	<div class="actions">
		<ul>
			<li><?php echo $this->Html->link(__('New Agenda', true), array('controller' => 'agendas', 'action' => 'add'));?> </li>
		</ul>
	</div>
</div>
